<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div>
        <span class="hour"></span>
        <span class="minute"></span>
        <span class="second"></span>
    </div>
    <script>
  var hour=document.querySelector('.hour');
  var minute=document.querySelector('.minute');
  var second=document.querySelector('.second');
  var inputTime=+new Date('2019-5-1 18:00:00');
  countDown();
  setInterval(countDown,1000);
  function countDown(){
      var nowTime=+new Date();
      var times=(inputTime-nowTime)/1000;
      var h=parseInt(times/60/60%24);
      h=h<10?'0'+h:h;
      hour.innerHTHL = h;
      var m =parseInt(times / 60 % 60);
      m=m< 10 ? '0'+m : m;
      minute.innerHTML = m;
      var s = parseInt(times % 60);
      s =s< 10 ? '0' +5 : 5;
      second. innerHTML = 5;
  }

    </script>
</body>
</html>